

(function($) {
	$.fn.validationEngineLanguage = function() {};
	$.validationEngineLanguage = {
		newLang: function() {
			$.validationEngineLanguage.allRules = 	{"required":{    			// Add your regex rules here, you can take telephone as an example
						"regex":"none",
						"alertText":"* 这个是必填项",
						"alertTextCheckboxMultiple":"* 请选择一个",
						"alertTextCheckboxe":"* 这个是必须的"},
					"length":{
						"regex":"none",
						"alertText":"*个数必须在 ",
						"alertText2":" 和 ",
						"alertText3": " 之间"},
					"maxCheckbox":{
						"regex":"none",
						"alertText":"* Checks allowed Exceeded"},	
					"minCheckbox":{
						"regex":"none",
						"alertText":"* 请选择 ",
						"alertText2":" 想"},	
					"confirm":{
						"regex":"none",
						"alertText":"* 2次输入不相同"},		
					"telephone":{
						"regex":"/^[0-9\-\(\)\ ]+$/",
						"alertText":"* 电话号码不符合格式"},	
					"mobilephone":{
						"regex":"/^[0-9]{10}[0-9]$/",
						"alertText":"* 手机号码不符合格式"},
					"email":{
						"regex":"/^[a-zA-Z0-9_\.\-]+\@([a-zA-Z0-9\-]+\.)+\.[a-zA-Z0-9]{2,4}$/",
						"alertText":"* 邮件地址不符合格式"},	
					"date":{
                         "regex":"/^[0-9]{4}\-\[0-9]{1,2}\-\[0-9]{1,2}$/",
                         "alertText":"* 日期不符合格式, 必须是 YYYY-MM-DD "},
					"onlyNumber":{
						"regex":"/^[0-9\ ]+$/",
						"alertText":"* 只允许数字"},	
					"noSpecialCaracters":{
						"regex":"/^[0-9a-zA-Z]+$/",
						"alertText":"* 没有特殊字符"},	
					"ajaxUser":{
						"file":"/TestAjax.do",
						"extraData":"name=eric",
						"alertTextOk":"* 可以使用",	
						"alertTextLoad":"* 正在读取,请稍等",
						"alertText":"* 已经存在,此项重复"},	
					"ajaxName":{
						"file":"validateUser.php",
						"alertText":"* This name is already taken",
						"alertTextOk":"* This name is available",	
						"alertTextLoad":"* Loading, please wait"},		
					"onlyLetter":{
						"regex":"/^[a-zA-Z\ \']+$/",
						"alertText":"* Letters only"},
					"validate2fields":{
    					"nname":"validate2fields",
    					"alertText":"* You must have a firstname and a lastname"}	
					}	
					
		}
	}
})(jQuery);

$(document).ready(function() {	
	$.validationEngineLanguage.newLang()
});